package com.gitee.faster.webdav.kernel.model;

import jakarta.xml.bind.annotation.*;
import lombok.Data;
import lombok.experimental.Accessors;

/**
 * @author hongda.li
 */
@SuppressWarnings("SpellCheckingInspection")
@Data
@Accessors(chain = true)
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "", propOrder = {
        "owner",
        "getEtag",
        "displayName",
        "resourceType",
        "getContentType",
        "getLastModified",
        "getContentLength"
})
@XmlRootElement(name = "prop")
public class Prop {

    private static final Prop ALL_PROP = new Prop();

    static {
        ALL_PROP.setOwner(new Owner());
        ALL_PROP.setGetEtag(new GetEtag());
        ALL_PROP.setDisplayName(new DisplayName());
        ALL_PROP.setResourceType(new ResourceType());
        ALL_PROP.setGetContentType(new GetContentType());
        ALL_PROP.setGetLastModified(new GetLastModified());
        ALL_PROP.setGetContentLength(new GetContentLength());
    }

    @XmlElement(name = "owner")
    private Owner owner;

    @XmlElement(name = "getetag")
    private GetEtag getEtag;

    @XmlElement(name = "displayname")
    private DisplayName displayName;

    @XmlElement(name = "resourcetype")
    private ResourceType resourceType;

    @XmlElement(name = "getcontenttype")
    private GetContentType getContentType;

    @XmlElement(name = "getlastmodified")
    private GetLastModified getLastModified;

    @XmlElement(name = "getcontentlength")
    private GetContentLength getContentLength;

    public static Prop allProp() {
        return ALL_PROP;
    }
}
